<template>
	<!-- 自定义列表 -->
	<view class="custom-list-container" :style="'margin-top:' + marginTop + 'rpx'" :class="isHeng?'heng': ''">
		<view class="list-title" v-if="title">
			<text :style="'fontSize:' + font + 'rpx'">{{title}}</text>
			<slot name="titleRightText"></slot>
		</view>
		<slot></slot>
	</view>
</template>

<script>
	export default {
		props: {
			title: {
				type: String,
				default: () => ''
			},
			marginTop: {
				type: Number,
				default: () => 66
			},
			isHeng: {
				type: Boolean,
				default: () => true
			},
			font: {
				type: Number,
				default: () => 24
			}
		}
	}
</script>

<style lang="scss" scoped>
	.custom-list-container {
		margin-top: 60rpx;
		padding-bottom: 20rpx;
		&.heng {
			border-bottom: 1px solid rgba(255, 255, 255, .1);
		}
		.list-title {
			display: flex;
			margin-bottom: 50rpx;
			color: #fff;
			justify-content: space-between;
		}
	}
</style>
